package com.zheng.utils.xmlUtil;

import freemarker.cache.CacheStorage;

import java.util.HashMap;
import java.util.Map;

/**
 * @author  
 *
 * 更改所生成类型注释的模板为
 * 窗口 > 首选项 > Java > 代码生成 > 代码和注释
 */
public class DcFtlCacheStorage implements CacheStorage
{

	protected final Map<Object, Object> localCache = new HashMap<Object, Object>();
	private String id;
	/* （非 Javadoc）
	 * @see freemarker.cache.CacheStorage#get(java.lang.Object)
	 */
	public DcFtlCacheStorage(String id) {
		this.id = id;
	}
    
	public Object get(Object key) {
		return localCache.get(key);
	}
    
	public void put(Object key, Object value) {
		localCache.put(key, value);
	}
    
	public void remove(Object key) {
		localCache.remove(key);
	}
    
	public void clear() {
		localCache.clear();
	}


}
